﻿using Max.PH5_2011A.Domain.Order;
using Max.PH5_2011A.IService;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;

namespace Max.PH5_2011A.API.Controllers
{
    [Route("order")]
    [ApiController]
    public class OrderController : ControllerBase
    {
        [HttpGet]
        public IActionResult Get()
        {
               var log = NLog.LogManager.GetCurrentClassLogger();
            try
            {
                //ViewBag[""] as DataTable
                //log.Info("一切正常");
                int a = 1, b = 0;
                int c = a / b;
                return Ok();
            }
            catch (Exception)
            {
                log.Error("出错");

            }
            return Ok();

        }


        [HttpGet("test")]
        public IActionResult Test()
        {
            System.Linq.Expressions.Expression<Func<OrderMasterModel, bool>> expression
                = null;
            //expression = x => x.Name.Contains("") || x.Age > 10;

            //System.Linq.Expressions.ParameterExpression param = null;

            return Ok();
        }
    }
}
